package cn.darkhorse.device.vo;

import cn.darkhorse.device.pojo.MesRepairWorkload;
import com.fhs.core.trans.anno.Trans;
import com.fhs.core.trans.constant.TransType;
import com.fhs.core.trans.vo.TransPojo;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.List;

/**
 * 检修保20240508最新vo
 */
@Data
public class MesRepairApplyInfoVO extends BaseEntity implements TransPojo {
    @ApiModelProperty("主键")
    private Long id;

    @ApiModelProperty("报修单号")
    @Excel(name = "报修单号",type = Excel.Type.EXPORT,sort = 12)
    private String applyNum;

    @ApiModelProperty("审核状态（0：待审1：待派工2：待维修3：维修中4:待验证5：已完成6：已驳回）")
    @Trans(type = TransType.DICTIONARY,key = "repairs_audit_status")
    @Excel(name = "处理状态",type = Excel.Type.EXPORT,sort = 1,dictType = "repairs_audit_status")
    private Integer auditStatus;

    @ApiModelProperty("处理结果")
    @Excel(name = "处理结果",type = Excel.Type.EXPORT,sort = 2)
    private String auditResult;

    @ApiModelProperty("所属部门")
    private Long dept;

    @Excel(name = "所属部门",type = Excel.Type.EXPORT,sort = 5)
    private String deptName;

    @ApiModelProperty("设备id")
    private Long deviceId;

    @ApiModelProperty("设备名称")
    @Excel(name = "设备名称",type = Excel.Type.EXPORT,sort = 4)
    private String deviceName;

    @ApiModelProperty("设备编号")
    private String deviceCode;

    @ApiModelProperty("设备代号")
    private String deviceMark;

    @ApiModelProperty("设备规格")
    private String deviceModel;

    @ApiModelProperty("设备类型")
    private Long deviceType;

    @ApiModelProperty("设备处置")
    @Trans(type = TransType.DICTIONARY,key = "disposal")
    private Integer disposal;

    @ApiModelProperty("验证描述/外委原因")
    private String reason;

    @ApiModelProperty("设备类型名称")
    @Excel(name = "设备类型",type = Excel.Type.EXPORT,sort = 6)
    private String deviceTypeName;
    @ApiModelProperty("设备位置")
    private String position;

    @ApiModelProperty("设备标签0：一般设备1：重点设备2:其他设备")
    @Trans(type = TransType.DICTIONARY,key = "device_tags")
    private Integer deviceTags;

    @ApiModelProperty("故障类别 0：机械故障1：电气故障")
    @Trans(type = TransType.DICTIONARY,key = "fault_category")
    @Excel(name = "故障类别",type = Excel.Type.EXPORT,sort = 11,dictType ="fault_category" )
    private Long malfunctionType;

    @ApiModelProperty("故障描述")
    @Excel(name = "故障描述",type = Excel.Type.EXPORT,sort = 7)
    private String malfunctionDescription;

    @ApiModelProperty("故障等级 0：紧急1：一般2：其他")
    @Trans(type = TransType.DICTIONARY,key = "failure_level")
    @Excel(name = "故障等级",type = Excel.Type.EXPORT,sort = 10,dictType ="failure_level" )
    private Integer malfunctionLevel;

    @ApiModelProperty("故障图片")
    private String malfunctionPic;

    @ApiModelProperty("紧急程度 0：紧急1：高2：中3：低")
    @Trans(type = TransType.DICTIONARY,key = "emergency_degree")
    private Integer urgency;

    @ApiModelProperty("报修人")
    @Excel(name = "报修人",type = Excel.Type.EXPORT,sort = 9)
    private String repairer;

    @ApiModelProperty("发生时间")
    private LocalDateTime repairDate;

    @ApiModelProperty("报修人电话")
    private String repairerPhone;

    @ApiModelProperty("维修单号")
    @Excel(name = "维修单号",type = Excel.Type.EXPORT,sort = 0)
    private String repairNum;

    @ApiModelProperty("是否停机 0：否1：是")
    private Integer isStop;

    @ApiModelProperty("故障来源 0：设备使用人1：巡检人员2：点检人员3：日常维护4:快速工单")
    @Trans(type = TransType.DICTIONARY,key = "fault_source")
    private Integer malfunctionSource;

    @ApiModelProperty("班组名称")
    @Excel(name = "维修组",type = Excel.Type.EXPORT,sort = 2)
    private String teamName;

    @ApiModelProperty("审核角色")
    private  String approvalRole;

    @ApiModelProperty("实际班组名称")
    private String realTeamName;

    @ApiModelProperty("维修人员")
    private String repairPersons;
    @ApiModelProperty("维修人员姓名")
    private String repairPersonsName;

    @ApiModelProperty("主修人")
    private Long mainRepairers;
    @ApiModelProperty("主修人")
    @Excel(name = "主修人",type = Excel.Type.EXPORT,sort = 3)
    private String mainRepairersName;

    @ApiModelProperty("实际是否停机 0：否1：是")
    private Integer realIsStop;

    @ApiModelProperty("故障原因")
    private Integer malfunctionReason;

    @ApiModelProperty("维修级别")
    private Integer repairLevel;

    @ApiModelProperty("维修类别")
    private Integer repairType;

    @ApiModelProperty("停机小时")
    private Integer stopHour;

    @ApiModelProperty("停机分钟")
    private Integer stopMinute;

    @ApiModelProperty("维修开始时间")
    private LocalDateTime repairStartTime;

    @ApiModelProperty("维修结束时间")
    private LocalDateTime repairEndTime;

    @ApiModelProperty("维修小时")
    private Integer repairHour;

    @ApiModelProperty("维修分钟")
    private Integer repairMinute;

    @ApiModelProperty("维修描述")
    private String repairDescription;
    @ApiModelProperty("维修费用")
    private BigDecimal repairCost;

    @ApiModelProperty("是否修复 0:否1：是")
    private Integer isFixed;

    @ApiModelProperty("是否更换配件（0：否1：是）")
    private Integer applyStatus;

    @ApiModelProperty("附件")
    private String attachments;

    @ApiModelProperty("音频附件")
    private String mediaAttachments;

    @ApiModelProperty("验证人")
    private Long verifier;
    @ApiModelProperty("验证人")
    private String verifierName;

    @ApiModelProperty("验证时间")
    private LocalDateTime verifyTime;

    @ApiModelProperty("创建时间")
    @Excel(name = "报修时间",type = Excel.Type.EXPORT,sort = 8,dateFormat = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime gmtCraeate;

    @ApiModelProperty("当前审核人")
    private Long currentApprover;
    @ApiModelProperty("审核意见")
    private List<MesRepairApprovalHistoryVO> approvalHistories;
    @ApiModelProperty("工作量")
    private List<MesRepairWorkload> workloadList;









}
